import request from "@/utils/request";

export const getRyList = (params) => {
  return request({
    url: "/api/user-service/user/search",
    method: "get",
    params,
  });
};

export const getEditList = (data, id) => {
  return request({
    url: `/api/user-service/user/${id}`,
    method: "put",
    data,
  });
};

export const getDeleteList = (id) => {
  return request({
    url: `/api/user-service/user/${id}`,
    method: "delete",
  });
};

export const getUserList = (params) => {
  return request({
    url: `/api/user-service/user/searchUserWork`,
    method: "get",
    params,
  });
};

export const getRoleList = (params) => {
  return request({
    url: `/api/user-service/role`,
    method: "get",
    params,
  });
};

export const getGdInfo = () => {
  return request({
    url: `/api/task-service/task/taskReportInfo/2020-01-01 00:00:00/2020-01-01 23:59:59`,
    method: "get",
    // params,
  });
};

export const getWorkDetail = () => {
  return request({
    url: `/api/task-service/task/userWork`,
    method: "get",
    // params,
  });
};

export const getUserDetail = (id) => {
  return request({
    url: `/api/user-service/user/${id}`,
    method: "get",
  });
};
